<!DOCTYPE html>
<html lang="en">
<head>
	<meta charset="UTF-8">
	<title>Document</title>
</head>
<body>
	<!-- 
	区间[0 1)
	//需求想生成36-24内的随机数
	36-12 = 24 ;  [0 1) * 24 + 12= [0 24) + 12

	 -->
	<script>
		console.log(parseInt(Math.random() * 24 + 12));
	</script>
</body>
</html>